package com.geeksaga.dao.ibatis.oracle;


import org.springframework.dao.DataAccessException;
import org.springframework.stereotype.Repository;

import com.geeksaga.dao.CharactersetDao;
import com.geeksaga.dao.ibatis.BaseIBatisDao;
import com.geeksaga.domain.Characterset;

/**
 * @author newbie
 * @since 0.1
 */
@Repository
public class CharactersetDaoImpl extends BaseIBatisDao implements CharactersetDao {

	/* (non-Javadoc)
	 * @see com.geeksaga.dao.CharactersetDao#add(com.geeksaga.domain.Characterset)
	 */
	public Characterset add(Characterset characterset) throws DataAccessException {
		return (Characterset) getSqlMapClientTemplate().insert("CHARACTERSET.add", characterset);
	}

	/* (non-Javadoc)
	 * @see com.geeksaga.dao.CharactersetDao#find(com.geeksaga.domain.Characterset)
	 */
	public Characterset find(Characterset characterset) throws DataAccessException {
		return (Characterset) getSqlMapClientTemplate().queryForObject("CHARACTERSET.find", characterset);
	}
}